import { createApp } from 'vue'
import App from './App.vue'
import router from './router/index.ts'

import ElementPlus from 'element-plus'
import 'element-plus/dist/index.css'
import zhCn from "element-plus/es/locale/lang/zh-cn"

import store from './store/index.ts'

import 'vant/es/toast/style';
import 'vant/lib/index.css';

import Particles from "particles.vue3";

import directive from './directive/index.ts'
import './assets/css/global.sass'
import { isMobile } from './utils/common.ts'

// 挂载全局变量
const app = createApp(App);
app.config.globalProperties.isMobile = isMobile()

app.use(directive)
app.use(router)
app.use(store)
app.use(Particles);
app.use(ElementPlus, {
  locale: zhCn,
})
app.mount('#app')